#ifndef CORECOMMON_H
#define CORECOMMON_H

#include <QtCore>
#include <memory>
#include <vector>

#define DECLARE_SMART_PTR(TYPE) typedef std::shared_ptr<TYPE> TYPE##Ptr; \
    typedef std::weak_ptr<TYPE> TYPE##Weak; \
    typedef TYPE* TYPE##RawPtr; \
    typedef QList<TYPE*> TYPE##RawPtrArray; \
    typedef QList<TYPE##Ptr> TYPE##PtrArray; \
    typedef QList<TYPE##Weak> TYPE##WeakArray;

namespace TA {

enum WordType{
    UNKNOW,CHINESE,LATIN,NUMBER
};

enum WordStatus{
    UNCHECKED,CHECKED,ADOPT
};

class Project;
class Word;
class WordGroup;
class WordPosition;
class Document;

class Statement;

DECLARE_SMART_PTR(Project)
DECLARE_SMART_PTR(Word)
DECLARE_SMART_PTR(WordGroup)
DECLARE_SMART_PTR(WordPosition)
DECLARE_SMART_PTR(Document)
DECLARE_SMART_PTR(Statement)

}

#endif // CORECOMMON_H
